package com.examples.chartdirector.service;

/** Http service for Biying API. */
public interface IBiyingService {
	String TestLicense="84AB3B08-971F-4B72-8F1C-006FBA3857CA";

	//https://api.biyingapi.com/hsstock/history/002265/d/f/84AB3B08-971F-4B72-8F1C-006FBA3857CA?lt=3
	String REMOTE_ADDR="api.biyingapi.com";
	String APP_DEFAULT_DOMAIN = "https://"+REMOTE_ADDR;

	void historyQuery(String code, Level level, Ex_rights type, int limit, OnResponseListener responseListener)
			throws Exception;

	public interface OnResponseListener {
		void onNext(String response);
	}

	enum Level {
		min5("5"), min15("15"), min30("30"), min60("60"), day("d"), week("w"), month("m"), year("y");

		Level(String level) {
			this.level = level;
		}

		public final String level;
	}
	
	enum Ex_rights {
		n,
		f,
		b,
		fr,
		br;
	}
}
